package com.user.service;

import com.user.entity.Payload;
import com.user.entity.ResultBody;
import com.user.entity.User;
import com.user.entity.UserInfo;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

public interface UserService {
    boolean checkData(String data, Integer type);

    String sendeCode(String phone);

    boolean register(User user, String code);

    ResultBody queryUserByName(String username, String password);

    String login(String username, String password);

    Payload<UserInfo> verifyUser(HttpServletRequest request, HttpServletResponse response);

    void logout(HttpServletRequest request, HttpServletResponse response);
}
